<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <link rel="stylesheet" href="css/element-ui.css">
    <link rel="stylesheet" href="css/index.css">
    <link rel="stylesheet" href="css/common.css" />
    <title>评价单位注册审核</title>
    <style type="text/css">
        html, body, #app {
            padding: 0px;
            margin: 0px;
            
        }
        #app{
        	border-top: 3px solid #0D9AFF;
           	background: #FFFFFF;
            box-shadow: 0px 2px 4px 0 rgba(200,200,200,0.50);
            padding: 25px;
            background: url(../images/bg.png) no-repeat;
			background-size: cover;
			/*background-attachment: fixed;*/
            overflow: hidden;
        }
		.tab-title{
			font-size: 16px;
			font-weight: bold;
			border-left: 4px solid #0D9AFF;
			font-family: PingFangSC-Medium;
			padding-left:10px;
			margin-bottom: 20px;
		}
		.el-dialog__footer {
			padding: 10px 20px 20px;
			text-align: center;
			-webkit-box-sizing: border-box;
			box-sizing: border-box;
		}
		.el-dialog__body {
			color: rgb(96, 98, 102);
			font-size: 14px;
			word-break: break-all;
			padding: 0px 20px;
		}
		#excel {
		    display: none;
		}
		.el-input__inner {
		    -webkit-appearance: none;
		    background-color: #FFF;
		    background-image: none;
		    border-radius: 4px;
		    border: 1px solid #DCDFE6;
		    -webkit-box-sizing: border-box;
		    box-sizing: border-box;
		    color: #606266;
		    display: inline-block;
		    font-size: inherit;
		    height: 30px;
		    line-height: 30px;
		    outline: 0;
		    padding: 0 15px;
		    -webkit-transition: border-color .2s cubic-bezier(.645,.045,.355,1);
		    transition: border-color .2s cubic-bezier(.645,.045,.355,1);
		    width: 100%;
		}
		.listed .el-form-item__label{
			letter-spacing: 3px;
		}
		.el-textarea {
			width: 95%;
		}	
    </style>
</head>

<body>
<div v-cloak id="app">
	<div style="margin-top: 10px;border-bottom: 1px solid #C8C8C8;">
		<el-form :model="selectForm" :rules="rules" ref="selectForm" label-width="140px">
			<el-row>
				<el-col :span="4" class="tab-title">
					基本信息
				</el-col>	
			</el-row>
		  	<el-row>
		  		<el-col :span="10">
					<el-form-item label="企业名称:" style="letter-spacing: 4px;" prop="enterpriseName" label-width="110px">
					   	<el-input v-model="selectForm.enterpriseName" style="width: 500px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col :span="6">
					<el-form-item label="统一社会信用代码:" prop="socialCode">
					   	<el-input v-model="selectForm.socialCode" style="width: 180px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col span="6">
				   	<el-form-item label="营业执照上传:" prop="fileName" label-width="110px">
						<el-input v-model="selectForm.fileName" style="width: 180px;" placeholder="不超过5M"></el-input>
						<input type="file" id="excel"ref="head" accept="" @change="checkType()" enctype="multipart/form-data"/>
						<el-button  size="small" style="width:75px;height: 30px;background: #E5E9F2;border-radius: 4px;color: #0D9AFF;" @click="selectFile()">选择文件</el-button>
				  	</el-form-item>
				</el-col>
	 		</el-row>

		  	<el-row>
			  	<el-col :span="10">
				  	<el-form-item label="企业所在地:" style="letter-spacing: 1.2px;" prop="enterpriseLocation" label-width="108px">				    	
				    	<el-select  v-model="selectForm.enterpriseLocation" placeholder="请选择" style="width: 150px;">
							<el-option label="已审核" value="1"></el-option>
							<el-option label="待审核" value="2"></el-option>
							<el-option label="已退回" value="3"></el-option>
						</el-select>
						<span style="color: #C0CCDA;;">—</span>
						<el-select  v-model="selectForm.processState" placeholder="请选择" style="width: 150px;">
							<el-option label="已审核" value="1"></el-option>
							<el-option label="待审核" value="2"></el-option>
							<el-option label="已退回" value="3"></el-option>
						</el-select>
						<span style="color: #C0CCDA;;">—</span>
						<el-select  v-model="selectForm.processState" placeholder="请选择" style="width: 150px;">
							<el-option label="已审核" value="1"></el-option>
							<el-option label="待审核" value="2"></el-option>
							<el-option label="已退回" value="3"></el-option>
						</el-select>
				  	</el-form-item>
			  	</el-col>
			  	<el-col :span="6">
				  	<el-form-item label="企业详细地址:" style="letter-spacing: 3.5px;" prop="unitType" label-width="140px">
						<el-input v-model="selectForm.unitType" style="width: 180px;" placeholder="" ></el-input>
				  	</el-form-item>
			  	</el-col>
			  	<el-col span="6">
				   	<el-form-item label="邮编:" style="letter-spacing: 14px;" prop="fileName" label-width="110px">
						<el-input v-model="selectForm.fileName" style="width: 180px;" placeholder=""></el-input>						
				  	</el-form-item>
				</el-col>
		  	</el-row>
		  	<el-row>
		  		<el-col :span="10">
					<el-form-item label="企业成立时间:"  prop="enterpriseName" label-width="110px">
					   	<el-input v-model="selectForm.enterpriseName" style="width: 500px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col :span="6">
					<el-form-item label="企业法人:" prop="socialCode" style="letter-spacing: 9px;">
					   	<el-input v-model="selectForm.socialCode" style="width: 180px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col span="6">
				   	<el-form-item label="上市情况:" prop="fileName" label-width="100px" class="listed">
						<el-radio-group v-model="radio2">
						    <el-radio :label="3">境外上市</el-radio>
						    <el-radio :label="6">境内上市</el-radio>
						    <el-radio :label="9">否</el-radio>
						</el-radio-group>
				  	</el-form-item>
				</el-col>
	 		</el-row>
	 		<el-row>
			  	<el-col :span="5">
				  	<el-form-item label="单位类型:" style="letter-spacing: 4px;" prop="unitType" label-width="110px">				    	
				    	<el-select  v-model="selectForm.unitType" placeholder="请选择" style="width: 180px;">
							<el-option label="已审核" value="1"></el-option>
							<el-option label="待审核" value="2"></el-option>
							<el-option label="已退回" value="3"></el-option>
						</el-select>
				  	</el-form-item>
			  	</el-col>
			  	<el-col :span="5">
				  	<el-form-item label="联系电话:" style="letter-spacing: 1px;" prop="contactPhone" label-width="100px">				    	
				    	<el-input v-model="selectForm.contactPhone" style="width: 180px;" placeholder="" ></el-input>
				  	</el-form-item>
			  	</el-col>
			  	<el-col :span="6">
				  	<el-form-item label="联系人:" style="letter-spacing: 14px;" prop="unitType" label-width="140px">
						<el-input v-model="selectForm.unitType" style="width: 180px;" placeholder="" ></el-input>
				  	</el-form-item>
			  	</el-col>
			  	<el-col span="6">
				   	<el-form-item label="企业邮箱:" style="letter-spacing: 4px;" prop="fileName" label-width="110px">
						<el-input v-model="selectForm.fileName" style="width: 180px;" placeholder=""></el-input>						
				  	</el-form-item>
				</el-col>
			  	<!--<div style="float: right;">
			  		<el-button type="primary" size="small" style="width: 60px;height: 30px;" @click="searchForm('selectForm')">查询</el-button>
			  		<el-button type="warning" size="small" style="width: 60px;height: 30px;" @click="resetForm('selectForm')">重置</el-button>
			  	</div>-->
			  	
		  	</el-row>
		  	<el-row>
		  		<el-col :span="10">
					<el-form-item label="办公电话:" style="letter-spacing: 4px;" prop="enterpriseName" label-width="110px">
					   	<el-input v-model="selectForm.enterpriseName" style="width: 500px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col :span="8">
				   	<el-form-item label="企业资质附近:" prop="fileName1" label-width="140px" style="letter-spacing: 4px;">
						<el-input v-model="selectForm.fileName" style="width: 180px;" placeholder=""></el-input>
						<input type="file" id="excel"ref="head" accept="" @change="checkType()" enctype="multipart/form-data"/>
						<el-button  size="small" style="width:75px;height: 30px;background: #E5E9F2;border-radius: 4px;color: #0D9AFF;" @click="selectFile()">选择文件</el-button>
				  	</el-form-item>
				</el-col>
	 		</el-row>
		</el-form>
		
 	</div>
	
	<div style="margin-top:30px;">
		<el-form :model="selectForm" :rules="rules" ref="selectForm" label-width="140px">
			<el-row>
				<el-col :span="4" class="tab-title">
					审批意见
				</el-col>	
			</el-row>
		  	<el-row>
		  		<el-col :span="10">
					<el-form-item label="审批人账户:" style="letter-spacing: 2px;" prop="enterpriseName" label-width="110px">
					   	<el-input v-model="selectForm.enterpriseName" style="width: 500px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
				<el-col :span="6">
					<el-form-item label="审批人机构信息:" prop="socialCode">
					   	<el-input v-model="selectForm.socialCode" style="width: 180px;" placeholder="" ></el-input>
					</el-form-item>
				</el-col>
	 		</el-row>
	 		<el-row>
			  	<el-col :span="5">
				  	<el-form-item label="审批结果:" style="letter-spacing: 4px;" prop="results" label-width="110px">				    	
				    	<el-select  v-model="selectForm.results" placeholder="请选择" style="width: 180px;">
							<el-option label="已审核" value="1"></el-option>
							<el-option label="待审核" value="2"></el-option>
							<el-option label="已退回" value="3"></el-option>
						</el-select>
				  	</el-form-item>
			  	</el-col>
			  	<el-col :span="5">
				  	<el-form-item label="审批时间:" style="letter-spacing: 1px;" prop="date" label-width="100px">				    	
				    	<el-input v-model="selectForm.date" style="width: 180px;" placeholder="" ></el-input>
				  	</el-form-item>
			  	</el-col>
		  	</el-row>
		  	<el-row>
		  		<el-col :span="23">
					<el-form-item label="审批意见:" style="letter-spacing: 4px;" prop="" label-width="110px">
					   	<el-input
						  type="textarea"
						  :autosize="{ minRows: 8, maxRows: 8}"
						  placeholder="请输入内容"
						  v-model="textarea3">
						</el-input>
					</el-form-item>
				</el-col>
	 		</el-row>
	 		<el-row>
	 			<el-col :span="22">
			 		<div style="float:right;">
						<el-button type="primary" size="small" style="width: 60px;height: 30px;" @click="">提交</el-button>
						<el-button type="info" size="small" style="width: 60px;height: 30px;" @click="">取消</el-button>
					</div>
				</el-col>
			</el-row>
		</el-form>
		
 	</div>
	   
			

	
</div>
<script src="js/vue.js"></script>
<script src="js/element-ui.min.js"></script>
<script src="js/axios.min.js"></script>
<script>
    var vm = new Vue({
        el: '#app',
        data() {
            return {
            	currentPage: 1, //默认显示页面为1
				pagesize: 5, // 每页的数据条数
				radio2:6,
				textarea3:'',
                registerForm: {
                    userName: "",
                    mobile: "",
                    email: "",
                    password: "",
                    password2: "",
                },
                selectForm : {
                  	socialCode:'',
                  	enterpriseName:'',
                  	fileName:'',
                  	enterpriseLocation:'',
                  	beforeDate:'',
                  	afterDate:'',
                  	contactPhone:'',
                  	processState:'',
                  	results:'',
                  	unitType:''
			 	},
		 		rules: {
                    enterpriseName: [{
                        required: true,
                        message: '请输入企业名称',
                        trigger: 'blur'
                    },
                        {
                            min: 2,
                            max: 10,
                            message: '长度在 2 到 10 个字符',
                            trigger: 'blur'
                        }
                    ],
                    socialCode: [{
                        required: true,
                        message: '请输入统一社会信用代码',
                        trigger: 'blur'
                    },
                        {
                            min: 2,
                            max: 10,
                            message: '长度在 2 到 10 个字符',
                            trigger: 'blur'
                        }],
                    fileName: [{
                        required: true,
                        message: '请上传营业执照',
                        trigger: 'blur'
                    },
                        {
                            
                            trigger: 'blur'
                        }],
                    enterpriseLocation: [{
                        required: true,
                        message: '请选择企业所在地',
                        trigger: 'blur'
                    },
                        {
                            min: 6,
                            message: '',
                            trigger: 'blur'
                        }
                    ],
                    unitType: [{
                        required: true,
                        message: '请选择单位类型',
                        trigger: 'blur'
                    },
                        {
                            min: 6,
                            message: '',
                            trigger: 'blur'
                        },
                        {
                            
                            trigger: 'blur'
                        }
                    ],
                    contactPhone: [{
                        required: true,
                        message: '',
                        trigger: 'blur'
                    },
                        {
                            min: 6,
                            message: '',
                            trigger: 'blur'
                        },
                        {
                            
                            trigger: 'blur'
                        }
                    ],
                    results: [{
                        required: true,
                        message: '请选择单位类型',
                        trigger: 'blur'
                    },
                        {
                            min: 6,
                            message: '',
                            trigger: 'blur'
                        },
                        {
                            
                            trigger: 'blur'
                        }
                    ],
                    date: [{
                        required: true,
                        message: '',
                        trigger: 'blur'
                    },
                        {
                            min: 6,
                            message: '',
                            trigger: 'blur'
                        },
                        {
                            
                            trigger: 'blur'
                        }
                    ],
                },
            }
            
        },
        methods: {           
            searchForm(selectForm) {              
                axios({
                    method: 'post',
                    url: '/user/register',
                    data: {
                        socialCode: this.selectForm.socialCode,
                        enterpriseName: this.selectForm.enterpriseName,
                        beforeDate: this.selectForm.beforeDate,
                        afterDate: this.selectForm.afterDate,
                        processState: this.selectForm.processState,
                        unitType: this.selectForm.unitType
                    }
                })
                .then(response => {
                    let data = response.data;
                    if (data.code == 200) {
                        
                    } else {
                        this.$message.error(data.msg);
                    }
                })
                .catch(function (error) {
                    console.log(error);
                });                  
            },
            resetForm(formName) {
            	console.log('sdsds')
		       	this.$refs[formName].resetFields();
		       	console.log('sdsds')
		    },
			/* getData() {

				// debugger
				 /!*axios.get('../common/data/datalist.json')*!/
				 axios('url',{
				     url:'/common/data/datalist.json',
					 method:'',
					 data:{
				         /!*参数*!/
					 }
				 })
				/!* .then({
					  console.log(response.data);
					    //this.datalist = response.data;
				 })*!/
			 },*/
			//检查上传类型
            checkType() {
		          let vm = this;
		          let allImgExt = '.xls|.xlsx|';
		          let filePath = this.$refs.head.value;
		          let extName = filePath.substring(filePath.lastIndexOf(".")).toLowerCase();
		          if (allImgExt.indexOf(extName + '|') === -1) {
		            this.$message("请选择正确的Excel文件");
		            this.$refs.head.value = '';
		            excelContent = [];
		            return;
		          }
		          let file = this.$refs.head.files[0];
		         this.selectForm.fileName = file.name;
		   
        	},
			//选取文件
			selectFile(){
				this.$refs.head.click();
			},
			 //每页下拉显示数据
			handleSizeChange: function(size) {
				this.pagesize = size;
				/*console.log(this.pagesize) */
			},
			//点击第几页
			handleCurrentChange: function(currentPage) {
				this.currentPage = currentPage;
				/*console.log(this.currentPage) */
			}
        }

    })
</script>
</body>
</html>